package me.ywd.comparison.web;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.mongodb.core.MongoTemplate;
import org.springframework.stereotype.Controller;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @Author Ye_Wenda
 * @Date 7/25/2017
 */
@Controller
@RequestMapping("/mongo")
public class MongoController {

    @Autowired
    private MongoTemplate mongoTemplate;

    @GetMapping("/hello/world")
    @ResponseBody
    @Transactional(readOnly = true)
    public String helloWorld() {
        return null;
    }
}
